within ThreeD_MBS_Dynamics.Examples.OmniVehicle;

model SlippingRollerTest

  parameter Real R = 1;
  parameter Real R1 = R/sqrt(2);
  parameter Real omega0 = 10;

  Base base;

  OnePortHeavyBody onePortHeavyBody(
    Gravity = {0, -1, 0},
    r(start = {0, R - R1, 0}),
    v(start = {0, 0, 0}),
    q(start = {1, 0, 0, 0}),
    omega(start = {omega0, 0, 0}));

  RollerOnPlaneSlipping rollerOnPlaneSlipping(
    xi(start = R - R1),
    rhoA(start = {0, 0, 0}),
    rhoB(start = {0, -(R - R1), 0}),
    lambda(start = -2*R));

  annotation (experiment(StopTime=10,
					     NumberOfIntervals=50000,
					     Tolerance=1e-006),
			  experimentSetupOutput);

equation

  connect(rollerOnPlaneSlipping.OutPortB, onePortHeavyBody.InPort);
  connect(rollerOnPlaneSlipping.InPortB, onePortHeavyBody.OutPort);
  connect(rollerOnPlaneSlipping.InPortA, base.OutPort);

end SlippingRollerTest;
